#include <iostream>
#include <cstdio>
#include <string>

using namespace std;

bool done[30];
int k;
string s;
int main()
{
    int rem,tot;
    cin>>k>>s;
    rem=tot=0;
    for(int i=1;i<=(s.size()+1)/2;i++)
    {
        char &a=s[i-1],&b=s[s.size()-i];
        //printf("%c %c\n",a,b);
        if(a=='?'&&b!='?') a=b,done[a-'a']=true;
        else if(b=='?'&&a!='?') b=a,done[a-'a']=true;
        else if(a!='?'&&b!='?'&&a!=b)
        {
            cout<<"IMPOSSIBLE"<<endl;
            return 0;
        }
        else if(a!='?'&&b!='?') done[a-'a']=true;
        else rem++;
    }
    for(int i=0;i<k;i++) if(!done[i]) tot++;
    if(tot>rem) cout<<"IMPOSSIBLE"<<endl;
    else
    {
        int j=0;
        for(int i=1;i<=(s.size()+1)/2;i++) if(s[i-1]=='?')
        {
            if(rem>tot)
            {
                s[i-1]=s[s.size()-i]='a';
                rem--;
                if(!done[0]) done[0]=true,tot--;
            }
            else
            {
                while(j<k&&done[j])j++;
                s[i-1]=s[s.size()-i]='a'+j;
                done[j]=true;
            }
        }
        cout<<s<<endl;
    }
    return 0;
}
